#!/bin/bash

# ***************************************************************************
# * 
# * @file:add_modules.sh 
# * @author:ebayboy@163.com 
# * @date:2020-08-18 01:41 
# * @version 1.0  
# * @description: Shell script 
# * @Copyright (c)  all right reserved 
#* 
#**************************************************************************/ 

REPO=$1
FILENAME=${REPO##*/}   
PROJECT=${FILENAME%%.*} 

if [ "$REPO" == "" ] || [ "$PROJECT" == "" ];then
	echo "Usage: ./$0 https://github.com/ebayboy/cJSON.git"
	exit
fi

CMD="git submodule add ${REPO}  vendors/${PROJECT}"
eval ${CMD}

